//
// Created by wkm on 2024-03-17.
//

#include "SubBytes.h"

//定义s盒字节代换替换操作
void SubBytes(unsigned char *col) {//字节代换
    int x;
    for (x = 0; x < 16; x++) {
        col[x] = sbox[col[x]];
    }
}

//逆向字节代换
void Contrary_SubBytes(unsigned char *col) {
    int x;
    for (x = 0; x < 16; x++) {
        col[x] = contrary_sbox[col[x]];
    }
}